package qj.ps.sla.vfg;

import java.awt.event.KeyEvent;

import qj.tool.jna.*;
import qj.tool.jna.KeyCombiMapper.Mapper;
import qj.util.Clipboard;
import qj.util.funct.P0;

public class EspMapper {
	public static void main(String[] args) {
		KeyboardHooks.init();
		Mapper mapper = KeyCombiMapper.mapper(KeyEvent.VK_ALT); //BACKQUOTE
		mapper.map('1', new P0() {public void e() {
			String text = Clipboard.getText();
			text = text.replaceAll("^v1:", "");
			Clipboard.type("$" + text);
		}});
		mapper.map('2', new P0() {public void e() {
			String text = Clipboard.getText();
			text = text.replaceAll("[\n<>]", "").trim();
			Clipboard.type(text);
		}});
	}
}
